<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <script>
        // var 变量名=变量值;
        var username="alice";//声明变量的同时赋值
        var age=20;
        var flag=true;
        var studentAverageScore=78;
        var a;//声明变量，定义变量

        //ES6中可以使用let声明变量
        let username2="huahua";
        console.log("姓名是"+username);
        console.log("年龄是"+age);
        console.log("婚否"+flag);
        console.log("平均分数"+studentAverageScore);
        console.log("富婆姓名:"+username2);
        console.log(a);//undefined

    </script>
</head>
<body>

</body>
</html>